<%@ Page Culture="en-US" UICulture="en-US" Language="C#" Explicit="true" Debug="true"%>

<%@ Import Namespace="System" %>
<%@ Import Namespace="System.Data" %>
<%@ Import Namespace="System.Data.SqlClient" %>
<%@ Import Namespace="System.Web.UI.WebControls" %>
<%@ Import Namespace="System.Data.OleDb" %>
<%@ Import Namespace="System.Globalization" %>
<%@ Import Namespace="System.Threading" %>

<Script language="C#" runat="server">

  //++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
  // To convert the SQL Server versions to MS Access do the following:-
  //   Replace the 2 DSN lines
  //   Replace all code of:-   SQLCommand   to   OleDbCommand
  //   Replace all code of:-   SQLDatareader   to   OleDbDatareader
  //   Replace Dates from '  to #   (do not need ' for SQL Server)   (eg strStartDate = "#" & strStartDate & "#")
  //  Change Function DateConvitfromformUS, also  (see comments in Function itself)
  //++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++


string strErrMsg;
string strPK_ID;
string strPageload;
string strmachine;


//Net 1.1
//SqlConnection objConn = new SqlConnection(ConfigurationSettings.AppSettings["DSN"]);
//Net 2.0
SqlConnection objConn = new SqlConnection(ConfigurationManager.AppSettings["DSN"]);

  //=======================================================================================
  // NOTE:-
  // Code that can be Customised are marked by &&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&
  //
  //=======================================================================================

    void Page_Load() 
    {
        
          if (!IsPostBack)                //initially coming into this web page from another external web page (eg array_list.aspx)
          {
             strPageload = "setFocus()";        //so as to focus on particular field on the page when loading

            //strdatenow = DateTime.Now;
            strPK_ID = Convert.ToString(Request.QueryString["num"]);     //get PK_ID key
            PK_ID.Value = strPK_ID;                                 //store as hidden variable on form, to keep while in this page
           
            //control.Value = Convert.ToString(Request.QueryString["textbox"]);

           
            //&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&
            //Next 2 lines are for when using datagrid List originating from, takeout if standalone
            SortFieldGetLOCAL.Value = Convert.ToString(Request.QueryString["sortby"]);            //Get Sortby from ARRAY_LIST
            PageSizeGetLOCAL.Value = Convert.ToString(Request.QueryString["pagesize"]);       //Get Pagesize from ARRAY_LIST
            //&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&


            GetYearList();
            GetMonthList();
            
          } 
          else     //when running post back within page 
          {   
             //Do Nothing
             strPageload = "";
             //strPageload = "setFocus()";
             //strPageload = "setPostBack()";
            //Response.Write(("Doing Postback within page " + "<br>\""));
           }
       
     }



    private void GetYearList() 
    {
        int indx;
        for (indx = 1900; (indx <= 2050); indx++) {
            ddlYear.Items.Add(new ListItem(indx.ToString(), indx.ToString()));
        }
        // Go to Current Year
        ddlYear.Items.FindByText(DateTime.Now.ToString("yyyy")).Selected = true;
    }


    private void GetMonthList() 
    {
        DataTable dt;
        DataRow dr;
        string strStatus;
        string strstatusread;

        // create a temporary DataTable for Month dropdownlist
        dt = new DataTable();
        dt.Columns.Add(new DataColumn("month", typeof(string)));
        dt.Columns.Add(new DataColumn("month_number", typeof(string)));

        dr = dt.NewRow();
        strStatus = "January";
        dr[0] = strStatus;
        dr[1] = "01";
        dt.Rows.Add(dr);

        dr = dt.NewRow();
        strStatus = "February";
        dr[0] = strStatus;
        dr[1] = "02";
        dt.Rows.Add(dr);

        dr = dt.NewRow();
        strStatus = "March";
        dr[0] = strStatus;
        dr[1] = "03";
        dt.Rows.Add(dr);

        dr = dt.NewRow();
        strStatus = "April";
        dr[0] = strStatus;
        dr[1] = "04";
        dt.Rows.Add(dr);

        dr = dt.NewRow();
        strStatus = "May";
        dr[0] = strStatus;
        dr[1] = "05";
        dt.Rows.Add(dr);

        dr = dt.NewRow();
        strStatus = "June";
        dr[0] = strStatus;
        dr[1] = "06";
        dt.Rows.Add(dr);

        dr = dt.NewRow();
        strStatus = "July";
        dr[0] = strStatus;
        dr[1] = "07";
        dt.Rows.Add(dr);

        dr = dt.NewRow();
        strStatus = "August";
        dr[0] = strStatus;
        dr[1] = "08";
        dt.Rows.Add(dr);

        dr = dt.NewRow();
        strStatus = "September";
        dr[0] = strStatus;
        dr[1] = "09";
        dt.Rows.Add(dr);

        dr = dt.NewRow();
        strStatus = "October";
        dr[0] = strStatus;
        dr[1] = "10";
        dt.Rows.Add(dr);

        dr = dt.NewRow();
        strStatus = "November";
        dr[0] = strStatus;
        dr[1] = "11";
        dt.Rows.Add(dr);

        dr = dt.NewRow();
        strStatus = "December";
        dr[0] = strStatus;
        dr[1] = "12";
        dt.Rows.Add(dr);

        ddltextmonth.DataValueField = "month_number";
        ddltextmonth.DataTextField = "month";
        ddltextmonth.DataSource = dt;
        ddltextmonth.DataBind();
        // Go to Current Month
        ddltextmonth.Items.FindByValue(DateTime.Now.ToString("MM")).Selected = true;
    }



    private void ddlMonth_SelectedIndexChanged(object sender, System.EventArgs e) 
    {
        SetCalendarDate();
    }
    
    private void ddlYear_SelectedIndexChanged(object sender, System.EventArgs e) 
    {
        SetCalendarDate();
    }


    void SetCalendarDate() 
    {
        DateTime dtNewDate;

        //dtNewDate = DateTime.Parse((Int16.Parse(ddltextmonth.SelectedItem.Text) + ("/1/" + Int16.Parse(ddlYear.SelectedItem.Text))));
        dtNewDate = DateTime.Parse((Int16.Parse(ddltextmonth.SelectedItem.Value) + ("/1/" + Int16.Parse(ddlYear.SelectedItem.Value))));
        calDate.TodaysDate = dtNewDate;
    }

 
    protected void Change_Date(object sender, System.EventArgs e) 
    {
        
        Session.LCID = 2057;
        textsdate.Text = calDate.SelectedDate.ToShortDateString();  
        
    }


  

</Script> 



<HTML>
<HEAD>
<TITLE>Calendar &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
</TITLE>
<META NAME="GENERATOR" Content="Microsoft FrontPage 4.0">
<META HTTP-EQUIV="PRAGMA" CONTENT="NO-CACHE">
<META HTTP-EQUIV="imagetoolbar" CONTENT="NO">


<Script LANGUAGE="JavaScript" src="ajax_xmlhttp.js">
</Script>

<Script LANGUAGE="JavaScript" src="scwCal.js">
</Script>

<Script LANGUAGE="JavaScript">
<!--

//-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
//This Section is for keeping the Modal form focused all the time (ie MODAL)
//-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
var wb;
var checkblur;
function init()
{
  checkblur = "False";
  //Must focus on a form element initially
  document.getElementById('tempinit').focus();   //Added field for POP-UP only

  if(navigator.appName == "Microsoft Internet Explorer")
   {
     elem=document.forms[0].elements;
     for(var i=0;i<elem.length;i++){
      elem[i].onfocus = function(){clearTimeout(wb);}
      elem[i].onblur = function(){wb=setTimeout('window.focus()',5)}
    }
    window.document.body.onblur = function(){checkonblur();}
   }
  else
   {
       elem=document.forms[0].elements;
       for(var i=0;i<elem.length;i++){
        elem[i].onfocus = function(){clearTimeout(wb);}
        elem[i].onblur = function(){wb=setTimeout('window.focus()',100)}
       }
       
   }

}


function checkonblur()
{
  if (checkblur == "False")
  {
       if(navigator.appName == "Microsoft Internet Explorer")
      {
        wb=setTimeout('window.focus()',50);
      }
      else
      {
       wb=setTimeout('window.focus()',100);
      }
  }

}


//-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
//END of  Section for keeping the form focused all the time.
//-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------



function setFocus()
{
    //alert("in setFocus");
    //init();

   //This is so to make changing months or year work
   document.getElementById('textsdate').value  = ".";
   //scwShow(textsdate,textsdate);
   document.getElementById('control').focus();
   //scwShow(textsdate,event);
}


function setPostBack()
{
     //alert("in setPostBack");
     //Next line sets overlay PNG image to visible again, on the Opening window
     window.opener.location = "javascript:KeepFocusClick();"
     init();
     SaveClick();
}


function onunloading() 
{
   //alert("in onul");
   //Mozilla does onul when clicking on any drop-down list(IE does not)
   if(navigator.appName == "Microsoft Internet Explorer")
   {
      window.opener.focus();
      window.opener.location = "javascript:FocusClick();"
      //onul();  
   }
   else
   {  
      //window.opener.focus();
      window.opener.location = "javascript:FocusClick();"
   }

}



//NEXT Part is AJAX Remote Scripting +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
//==============================================================================================================

 function show_savepage(actionit, sortby, pagesize)
 {                       
                   //&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&
                   //Change ajax called program name (ie AJAX_CAL_EDIT)
                   var requestURLIT = 'ajax_kgrid_caledit.aspx?action=' + actionit 
                   //&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&
                   var url = requestURLIT + '&sortby=' + sortby 
                   url = url + '&pagesize=' + pagesize
                   url = url + '&num=' + document.getElementById('PK_ID').value
                   //url = url + '&linkid=' + document.getElementById("LINKPK_ID").value   //OPTIONAL need LINKPK_ID key as well to get specific records

                   //&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&
                   //Add Field Data to be saved here (put escape on all text fields)
                   url = url + '&startdatetosave=' + document.getElementById('textsdate').value
                   url = url + '&datenametosave=' + document.getElementById('control').value
                  //&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&
 
                   //alert("url is " + url);
	   xmlHttp = GetXmlHttpObject(stateChangeHandlerSAVE); 
	   xmlHttp_Get(xmlHttp, url); 
}


//Next function is just for delaying the Error Message a bit.
//-------------------------------------------------------------------
function ShowAlert(str1) 
{ 
 alert(str1); 
}

//=======================================================================================================================================================
// Next functions are run after the above functions, so as to see when the Remote page has been completed
// stateChangeHandler will fire when the state has changed, i.e. data is received back 
// This is non-blocking (asynchronous) 
//=======================================================================================================================================================
function stateChangeHandlerSAVE() 
{ 
                                           var rowID1;
		            //readyState of 4 or 'complete' represents that data has been returned 
		           if (xmlHttp.readyState == 4 || xmlHttp.readyState == 'complete')
                                           { 
		                //Gather the results from the callback 
			var str = xmlHttp.responseText; 
                                           
                                             //If validation Error found, then display error concerned
                                             if (str.substring(0,5) == "Error")
                                             {
                                                //setTimeout("ShowAlert(' " + str + " ')",100);
                                             }
                                             else
                                             {
                                              //If No Error then
                                              //&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&
                                              //The next Part is you are using a datagrid LIST originating from (so can be taken out for standalone add form)
                                              //---------------------------------------------------------------------------------------------------------------------------------
                                              //Get PageID, Rowid, SkipCount, Sortby and PK_ID from AJAX_ADD_POPUP, and display on this form
                                             //document.getElementById('nameList3').innerHTML = str;


                                             parent.document.getElementById('nameList2').innerHTML = str;
                                             rowID1 = parent.document.getElementById('RowIDGet').value;
                                             parent.resetablebg();
                                                //set column sort header to a different background color
                                                parent.setBgColor(parent.document.getElementById('SortFieldGet').value);
                                                var table = parent.document.getElementById('myTable');
                                                if (table)   
                                                {
                                                 //Highlight 1st Row of new Page
                                                 table.rows[rowID1].style.backgroundColor="silver";
                                                 //&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&
                                                 //Highlight Input Textbox row as well (Comment out if no Input Textbox used in List)
                                                 //parent.document.getElementById('aa' + rowID1 + 'c7').style.backgroundColor="silver";
                                                 //&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&
                                                }   
                                                //------------------------------------------------------------------------------------------------------------------------
                                                //END of Part if using a datagrid LIST inconjunction (so can be taken out for standalone update form
                                               //&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&
                                              //&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&
                                              //display record in bottom framed page  (NOTE:- This part can be commented out if no framed detail record)
                                               //window.opener.parent.ARRAYSUPD.location.href="ARRAYS_UPD.aspx?action=upd" +
                                                //              "&num=" + document.getElementById('PK_ID').value;
                                             //&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&
                                              

                                             if(navigator.appName == "Microsoft Internet Explorer")
                                              {
                                                var t=setTimeout("ClosingIE()",200);
                                              
                                              }
                                             else
                                              {
                                                var t=setTimeout("ClosingMOZ()",200);
                                                
                                              }

  

                                            }  // if (str.substring(0,5) == "Error")
                                             
		          }   // if (xmlHttp.readyState == 4 || xmlHttp.readyState == 'complete')
} 


 function ClosingIE()
 {
     //alert("About to close");
     //window.close(); 
     parent.CloseCal();
 }


 function ClosingMOZ()
 {
     //alert("About to close");
     //window.close();
     parent.CloseCal();
     //window.opener.location = "javascript:CloseCal();"
 }



//&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&
//The following 2 functions are only used if having datagrid LIST being used in conjunction, so takeout for standalone
//----------------------------------------------------------------------------------------------------------------------------------------------------------------
function resetablebg()
{
 var table = parent.document.getElementById('myTable');

 if (table)   
  {
   //Make all rows white again
   for (var r = 0; r < table.rows.length; r++)
   {
     table.rows[r].style.backgroundColor="white";
     //&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&
     //Reset Input Textbox row as well (Comment out if no Input Textbox used in List)
     //window.opener.document.getElementById('aa' + r + 'c7').style.backgroundColor="white";
     //&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&
   }
  }             
}
function setBgColor(id) 
{
  //alert("in setBgcolor");
 var table = parent.document.getElementById(id);

 if (table)
  {
     parent.document.getElementById(id).style.backgroundColor = "blue";
  }
}
//&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&




//Will close window
//---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
function CancelClick()
{
 //alert("Cancel"); 
 //window.close();
 parent.CloseCal();

}


function SaveClick()
{
 var sortby = "";
 var pagesize = 0;
 var action1 = "byit";

 //&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&
 //The following lines are when there is a LIST originating from, comment out for standalone
 var sortby = document.getElementById('SortFieldGetLOCAL').value;
 var pagesize = document.getElementById('PageSizeGetLOCAL').value;
//&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&
 
 show_savepage(action1, sortby, pagesize);
}



//--> 
</Script>


</HEAD>

<!-- Please Note:- onFocus and onClick is only used if any Modal POPUP is being initiated from this Modal POPUP itself form-->
<BODY bgColor=white onload="<%=strPageload%>;">

<form id="form1" method="post" runat="server">

<!-- +++++++++++++++++++++++++++++++++++++++++++++++++++++++++-->
<!-- Storing HIDDEN variables (MANDATORY) -->
<!-- +++++++++++++++++++++++++++++++++++++++++++++++++++++++++-->
<!-- next 2 are ASP.NET type hidden variables -->

<!-- next line is Optional (used so as to see at bottom of form)-->
<br><br><br><br><br><br><br><br><br><br>

<!--Next variable is for Modal POP-UP Add only, so as to focus initially--> 
<asp:TextBox id="tempinit"
           style="BORDER-TOP: 1px solid black;
                      BORDER-BOTTOM: 1px solid black;
                      BORDER-LEFT: 0px solid black;
                      BORDER-RIGHT: 0px solid black"
     readonly="true"
      tabIndex="-1"
      runat="server" 
     AutoCompleteType="Disabled">
</asp:TextBox>

<input onfocus='scwShow(control,event);' id=control style="VISIBILITY: visible" 
        type="text" runat="server" />

<input id=PK_ID style="VISIBILITY: hidden" 
        type="text" runat="server" />

<!--OPTIONAL for when using another liked PK, can leave in--> 
<input id=LINKPK_ID style="VISIBILITY: hidden" 
        type="text" runat="server" />


<!--Next 2 variables are for when interacting with a datagrid List, originally coming from--> 
<input id=SortFieldGetLOCAL style="VISIBILITY: hidden" 
        type="text" runat="server" />

<input id=PageSizeGetLOCAL style="VISIBILITY: hidden" 
        type="text" runat="server" />

<!-- next Hidden variable is for displaying the Progress Bar via Javascript -->
<input id=ProgressBar style="VISIBILITY: hidden" 
        type="text" runat="server" />

<!-- +++++++++++++++++++++++++++++++++++++++++++++++++++++++++-->
<!-- END Storing HIDDEN variables (MANDATORY) -->
<!-- +++++++++++++++++++++++++++++++++++++++++++++++++++++++++-->


<!--span style="POSITION: absolute; 
             LEFT: 2px;  
             TOP: 2px; 
             HEIGHT: 220px;
             WIDTH: 800px;
             BACKGROUND-COLOR: white;
             COLOR: black;
             FONT-WEIGHT: normal;
             FONT-SIZE: 14px; 
             FONT-FAMILY: arial; 
             FONT-STYLE: normal; 
             BORDER-TOP: black 2px double;
             BORDER-BOTTOM: black 2px double;
             BORDER-LEFT: black 2px double;
             BORDER-RIGHT: black 2px double"> 
</span>-->



<asp:TextBox id="textsdate" 
      style="POSITION: absolute; 
             LEFT: 91px;  
             VISIBILITY: hidden;
             TOP: 4px; 
             HEIGHT: 21px;
             WIDTH: 70px;
             BACKGROUND-COLOR: white;
             COLOR: black;
             FONT-WEIGHT: normal;
             FONT-SIZE: 12px; 
             FONT-FAMILY: arial; 
             FONT-STYLE: normal; 
             Z-INDEX: 100"       
      tabIndex="3"
      runat="server">
</asp:TextBox>


<!--Start of Year-->            
<asp:Label id="Year1" 
             style="FONT-WEIGHT: bold; 
                    FONT-SIZE: 12px; 
                    Z-INDEX: 100; 
                    LEFT: 5px; 
                    COLOR: black; 
                    FONT-STYLE: normal; 
                    FONT-FAMILY: arial; 
                    POSITION: absolute; 
                    TOP: 4px; 
                    BACKGROUND-COLOR: white" 
                    runat="server" height="21" width="100">
               Year:
</asp:Label>
    
<asp:DropDownList id="ddlYear" 
     style="POSITION: absolute; 
            LEFT: 36px;  
            TOP: 4px; 
            HEIGHT: 21px;
            WIDTH: 50px;
            BACKGROUND-COLOR: white;
            COLOR: navy;
            FONT-WEIGHT: bold;
            FONT-SIZE: 11px; 
            FONT-FAMILY: arial; 
            FONT-STYLE: normal; 
            Z-INDEX: 100"    
     tabIndex="1"
     runat="server"
     AutoPostBack="True"
     OnSelectedIndexChanged="ddlYear_SelectedIndexChanged">
</asp:DropDownList>


<!--Start of Month-->            
<asp:Label id="Month1" 
             style="FONT-WEIGHT: bold; 
                    FONT-SIZE: 12px; 
                    Z-INDEX: 100; 
                    LEFT: 98px; 
                    COLOR: black; 
                    FONT-STYLE: normal; 
                    FONT-FAMILY: arial; 
                    POSITION: absolute; 
                    TOP: 4px; 
                    BACKGROUND-COLOR: white" 
                    runat="server" height="21" width="100">
               Month:
</asp:Label>
    
<asp:DropDownList id="ddltextmonth" 
     style="POSITION: absolute; 
            LEFT: 137px;  
            TOP: 4px; 
            HEIGHT: 21px;
            WIDTH: 89px;
            BACKGROUND-COLOR: white;
            COLOR: navy;
            FONT-WEIGHT: bold;
            FONT-SIZE: 11px; 
            FONT-FAMILY: arial; 
            FONT-STYLE: normal; 
            Z-INDEX: 100"    
     tabIndex="1"
     runat="server"
     AutoPostBack="True"
     OnSelectedIndexChanged="ddlMonth_SelectedIndexChanged">
</asp:DropDownList>




<!-- **********************************************************************************************************************************-->
<!-- START OF DATE Control on Form *****************************************************************************************-->
<!-- **********************************************************************************************************************************-->

<!--The next 3 controls make up the Calendar, which always will be displayed in the same place on the screen-->
<!--Please change the following code only:-  TextBox id, Calendar id, button id, onselectionchanged, onclick -->
<asp:TextBox id="caldatelabel" 
      style="POSITION: absolute; 
             LEFT: 5px;  
             TOP: 28px; 
             HEIGHT: 21px;
             WIDTH: 220px;
             BACKGROUND-COLOR: blue;
             COLOR: yellow;
             FONT-WEIGHT: bold;
             FONT-SIZE: 12px; 
             FONT-FAMILY: arial; 
             FONT-STYLE: normal; 
             TEXT-ALIGN: center; 
             BORDER-TOP: 1px solid black;
             BORDER-BOTTOM: 0px solid black;
             BORDER-LEFT: 1px solid black;
             BORDER-RIGHT: 1px solid black;
             Z-INDEX: 300"       
      readonly="True"
      Visible="true"
      runat="server">
</asp:TextBox>
<asp:Calendar id="calDate"
              style="Z-INDEX: 300;
                     LEFT: 5px;
                     BACKGROUND-COLOR: white;
                     POSITION: absolute;
                     BORDER-TOP: 0px solid black;
                     BORDER-BOTTOM: 0px solid black;
                     BORDER-LEFT: 0px solid black;
                     BORDER-RIGHT: 0px solid black;
                     TOP: 49px"
            runat="server"
            Height="210px"
            Width="220px"
            OnSelectionChanged="Change_Date"
            Visible="true"
            BackColor="White" BorderColor="Black" BorderStyle="Groove">

            <NextPrevStyle forecolor="White"></NextPrevStyle>
            <TitleStyle forecolor="White" backcolor="Blue"></TitleStyle>
            <OtherMonthDayStyle forecolor="White"></OtherMonthDayStyle>
</asp:Calendar>

<!-- **********************************************************************************************************************************-->
<!-- END OF DATE Control on Form *****************************************************************************************-->
<!-- **********************************************************************************************************************************-->


                  

<div id="nameList2">

</div>


<div id="nameList3">

</div>

      


</FORM>


</BODY>
</HTML>


